<%@ Page Language="C#" AutoEventWireup="true" CodeFile="PurchaseEdit.aspx.cs" Inherits="admin_Trade_PurchaseView" %>

<%@ Register Assembly="FredCK.FCKeditorV2" Namespace="FredCK.FCKeditorV2" TagPrefix="FCKeditorV2" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>修改求购信息</title>
    <link rel="stylesheet" href="../skin/style.css" type="text/css" />
</head>

<script type="text/javascript" src="../../js/calendar.js"></script>

<script language="javascript" src="../../js/Industry.js" type="text/javascript"></script>

<script type="text/javascript">
    function  textValue(){
          var   c=document.all('dropUnit');  
          var danwei=c.options[c.selectedIndex].value;
          zuixiaoqi.innerHTML="元/"+danwei;
          gonghuo.innerHTML=danwei;     
      }   
</script>

<script type="text/javascript">
  function validateslec()
  {
   if(document.getElementById("txtName").value==""){
        window.location.href="#flagKeyword";
        return false;
   }
   if(document.getElementById("txtKey").value==""){
        window.location.href="#flagKeyword";
        return false;
   }
    var righticon="../../images/websen.gif";
    var variale=0;
  if(document.getElementById("SortB").selectedIndex == -1) {
	         document.getElementById("txt10").innerHTML = "<img src="+righticon+" align=\"absmiddle\"> <font color=#FF0000>请选择所属行业和产品类目！</font>";
	         variale=1;
    }
   else
    {
       document.getElementById("txt10").innerHTML="";
    }
  if(variale!=0){
         window.location.href="#flagKeyword";
         return false;
     }
 else{
        document.getElementById("txt10").innerHTML="";
        return true;
     }
  }
</script>

<body>
    <form id="form1" runat="server" action="" onsubmit="return validateslec();">
        <asp:HiddenField ID="txtSortB" runat="server"></asp:HiddenField>
        <asp:HiddenField ID="txtSortM" runat="server"></asp:HiddenField>
        <asp:HiddenField ID="txtSortS" runat="server"></asp:HiddenField>
        <asp:HiddenField ID="txtSortF" runat="server"></asp:HiddenField>
        <asp:HiddenField ID="txtSortW" runat="server"></asp:HiddenField>
        <div class="itemtitle_tect">
            <ul>
                <li>产品关键字请出现在标题中，可让您的信息更容易被搜索到。</li>
                <li>详细的产品简介，可提高客户关注度。</li>
            </ul>
        </div>
        <asp:HiddenField ID="HiddenField1" runat="server"></asp:HiddenField>
        <asp:HiddenField ID="HiddenField2" runat="server"></asp:HiddenField>
        <asp:HiddenField ID="HiddenField3" runat="server"></asp:HiddenField>
        <asp:Label ID="lblMessage" runat="server" Visible="false" ForeColor="red"></asp:Label>
        <div class="talbe_border">
            <!--a name="flagKeyword"></a-->
            <table border="0" cellpadding="0" cellspacing="0" class="talbe_list">
                <tr>
                    <th colspan="2" class="header tou">
                        编辑求购信息</th>
                </tr>
                <tr>
                    <td width="14%" class="left1">
                        产品名称：<span>*</span></td>
                    <td class="left2">
                        <span>
                            <asp:TextBox MaxLength="20" ID="txtName" runat="server" Width="200px">
                            </asp:TextBox></span>
                        <div id="txt0">
                        </div>
                    </td>
                </tr>
                <tr>
                    <td class="left1">
                        产品关键字：<span class="red">*</span></td>
                    <td class="left2">
                        <span>
                            <asp:TextBox MaxLength="16" ID="txtKey" runat="server" Width="200px">
                            </asp:TextBox></span><div id="txt1">
                            </div>
                    </td>
                </tr>
                <tr>
                    <td class="left1">
                        产品所属类目：<span class="red">*</span></td>
                    <td class="left2">
                        <span>
                            <select id="SortB" name="SortB" runat="server" size="8" style="width: 132px">
                            </select>
                            <select id="SortM" name="SortM" runat="server" size="8" style="width: 132px">
                            </select>
                            <select id="SortS" name="SortS" runat="server" size="8" style="width: 132px">
                            </select>
                    <select id="SortF" name="SortF" runat="server" size="8" style="width: 132px">
                    </select>
                    <select id="SortW" name="SortW" runat="server" size="8" style="width: 132px">
                    </select>
                        </span>
                        <div id="txt10">
                        </div>
                    </td>
                </tr>
                <tr>
                    <a name="xiangxi"></a>
                    <td class="left1">
                        有效期：<span class="red">*</span>
                    </td>
                    <td class="left2">
                        <span>
                            <asp:RadioButtonList ID="RadioTime" runat="server" RepeatDirection="Horizontal" RepeatLayout="Flow">
                                <asp:ListItem Value="10">10天</asp:ListItem>
                                <asp:ListItem Value="20">20天</asp:ListItem>
                                <asp:ListItem Value="30">1个月</asp:ListItem>
                                <asp:ListItem Value="90">3个月</asp:ListItem>
                                <asp:ListItem Selected="True" Value="180">6个月</asp:ListItem>
                            </asp:RadioButtonList>
                        </span>
                        <div id="txt20">
                        </div>
                        <div id="txt30">
                        </div>
                    </td>
                </tr>
                <tr>
                    <td class="left1">
                        包装说明：
                    </td>
                    <td class="left2">
                        <span>
                            <asp:TextBox MaxLength="40" ID="txtBrand" runat="server" Width="133px"></asp:TextBox></span>
                        <div id="txt2">
                        </div>
                    </td>
                </tr>
                <tr>
                    <td class="left1">
                        产品规格：</td>
                    <td class="left2">
                        <span>
                            <asp:TextBox MaxLength="40" ID="txtModel" runat="server" Width="131px"></asp:TextBox></span>
                        <div id="txt3">
                        </div>
                    </td>
                </tr>
                <tr>
                    <td class="left1">
                        <strong>详细说明：</strong>
                    </td>
                    <td>
                        <FCKeditorV2:FCKeditor ID="txtContent" runat="server" BasePath="~/Control/fckeditor/"
                            ToolbarSet="Basic" Height="300" Width="639">
                        </FCKeditorV2:FCKeditor>
                    </td>
                </tr>
                <tr>
                    <td class="left1">
                        产品图片：
                    </td>
                    <td>
                        <div style="float: left">
                            <asp:HiddenField ID="ImgUrl1" runat="server" />
                            <a href="" id="txturldz" target="_blank">
                                <img src="../../Images/System/wutu1.gif" alt="" name="ImgUrl" width="98" height="98"
                                    border="0" id="ImgUrl" runat="server" /></a><br />
                            <input id="txtupload" type="button" value="上传" onclick="return rowTest()" /><br />
                            <div id="rowTest" style="display: none">
                                <iframe name="tag" src="../UpFile/Upload.html" frameborder="0" scrolling="no" onload="this.height=tag.document.body.scrollHeight"
                                    class="iframe_main"></iframe>
                            </div>
                            <div id="UpLoad">
                            </div>
                        </div>
                    </td>
                </tr>
                <tr>
                    <td class="left1">
                        <strong>计量单位：</strong>
                    </td>
                    <td class="left2">
                        <asp:DropDownList ID="dropUnit" runat="server" onchange="textValue();">
                        </asp:DropDownList>
                    </td>
                </tr>
                <tr>
                    <td class="left1">
                        需求数量：
                    </td>
                    <td class="left2">
                        <span>
                            <asp:TextBox onkeyup="if(event.keyCode!=37&&event.keyCode!=39)value=value.replace(/\D/g,'');"
                                ID="txtCount" runat="server" Width="75px" MaxLength="7" Text="10"></asp:TextBox></span>
                        <div id="gonghuo" runat="server">
                            包
                        </div>
                        <div id="txt4" style="color: Gray; float: left">
                        </div>
                    </td>
                </tr>
                <tr>
                    <td class="left1">
                        产品单价：
                    </td>
                    <td class="left2">
                        <span>
                            <asp:TextBox ID="txtPrice" runat="server" Width="75px" MaxLength="7" Text="1"></asp:TextBox></span>
                        <div id="zuixiaoqi" runat="server">
                            元/包</div>
                    </td>
                </tr>
            </table>
        <table border="0" cellpadding="0" cellspacing="0" class="talbe_list">
            <tr>
                <td colspan="2" class="header tou">
                    会员联系方式</td>
            </tr>
            <tr>
                <td class="left1">
                    姓名：</td>
                    <td class="left2">
                        <asp:Label ID="UserName" runat="server" Text=""></asp:Label>
                    </td>
            </tr>
            <tr>
                <td class="left1">
                    电话：</td>
                    <td class="left2">
                        <asp:Label ID="UserTelephone" runat="server" Text=""></asp:Label>
                    </td>
            </tr>
            <tr>
                <td class="left1">
                    QQ：</td>
                <td class="left2">
                    <asp:Label ID="UserChuanzhen" runat="server" Text=""></asp:Label>
                </td>
            </tr>
            <tr>
                <td class="left1">
                    公司名称：</td>
                <td class="left2">
                    <asp:Label ID="CompanyName" runat="server" Text=""></asp:Label>
                </td>
            </tr>
            <tr>
                <td class="left1">
                    Email：</td>
                <td class="left2">
                    <asp:Label ID="Email" runat="server" Text=""></asp:Label>
                </td>
            </tr>
            <tr>
                <td colspan="2" align="center">
                    <asp:Button Style="cursor: hand" ID="btnSave" runat="server" Text="确定" OnClick="btnSave_Click"
                        CssClass="i_button" />
                </td>
            </tr>
        </table>
        </div>
    </form>

    <script type="text/javascript" src="../../js/Industry.js"></script>

    <script language="javascript" type="text/javascript">
	    initialize(0);
    </script>

    <script type="text/javascript" src="../../js/Common.js"></script>

    <script type="text/javascript" src="../../js/jquery-cn.js"></script>

    <script type="text/javascript" src="../js/Purchase.js"></script>

</body>
</html>
